package com.rb.domain;

import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;

/**
 * Created by Brooks on 2014/5/7.
 */
@Entity
public class 调研题库 {
    private String id;
    private String 调研Id;
    private String 题目描述;
    private String 题目类型;

    @Id
    @Column(name = "id")
    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    @Basic
    @Column(name = "调研id")
    public String get调研Id() {
        return 调研Id;
    }

    public void set调研Id(String 调研Id) {
        this.调研Id = 调研Id;
    }

    @Basic
    @Column(name = "题目描述")
    public String get题目描述() {
        return 题目描述;
    }

    public void set题目描述(String 题目描述) {
        this.题目描述 = 题目描述;
    }

    @Basic
    @Column(name = "题目类型")
    public String get题目类型() {
        return 题目类型;
    }

    public void set题目类型(String 题目类型) {
        this.题目类型 = 题目类型;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        调研题库 调研题库 = (调研题库) o;

        if (id != null ? !id.equals(调研题库.id) : 调研题库.id != null) return false;
        if (调研Id != null ? !调研Id.equals(调研题库.调研Id) : 调研题库.调研Id != null) return false;
        if (题目描述 != null ? !题目描述.equals(调研题库.题目描述) : 调研题库.题目描述 != null) return false;
        if (题目类型 != null ? !题目类型.equals(调研题库.题目类型) : 调研题库.题目类型 != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = id != null ? id.hashCode() : 0;
        result = 31 * result + (调研Id != null ? 调研Id.hashCode() : 0);
        result = 31 * result + (题目描述 != null ? 题目描述.hashCode() : 0);
        result = 31 * result + (题目类型 != null ? 题目类型.hashCode() : 0);
        return result;
    }
}
